#pragma once

// CAutoJoinDlg dialog

class CAutoJoinDlg : public CDialog
{
	DECLARE_DYNAMIC(CAutoJoinDlg)

public:
	static const int HK_F7 = 1;
	static const int HK_F8 = 2;

	static const int TIMER_CHECK	= 1;
	static const int TIMER_TIMEOUT	= 2;
	static const int TIMER_JOIN		= 3;
	static const int TIMER_HIDE		= 4;
	static const int TIMER_QUIT		= 5;
	static const int TIMER_AUTHEN	= 6;
	static const int TIMER_TUNNEL	= 7;

	CAutoJoinDlg(IMainDlg* dlgMain, CWnd* pParent, ISetting* setting, ILang *lang);   // standard constructor
	virtual ~CAutoJoinDlg();

// Dialog Data
	enum { IDD = IDD_AUTOJOIN };

protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	virtual BOOL OnInitDialog();
	LRESULT OnHotKey(WPARAM wp, LPARAM lp);

	DECLARE_MESSAGE_MAP()

	ISetting* setting;
	ILang* lang;
	static CAutoJoin* autojoin;
	CBalloon* balloon;
	IMainDlg* dlgMain;

public:
	static HHOOK hookMouse;

public:
	static LRESULT CALLBACK OnGlobalMouseAction(int nCode, WPARAM wParam, LPARAM lParam) ;
};
